package com.totoro.mall.mall_buyer.enums;

import lombok.Getter;

/**
 * 错误码
 * Created by Niki on 2018/4/12 8:14
 */
@Getter
public enum ResultEnum implements CodeEnum {
    SUCCESS(0, "成功"),
    PARAM_ERROR(1, "参数不正确"),
    PRODUCT_NOT_EXIST(10, "商品不存在"),
    PRODUCT_STOCK_ERROR(11, "商品库存不正确"),
    PRODUCT_STATUS_ERROR(12, "商品状态不正确"),;
    private Integer code;

    private String message;

    ResultEnum(Integer code, String message) {
        this.code = code;
        this.message = message;
    }
}
